<template>
	<view class="hun" style="background-color: #EEEEEE;position: relative;height: 100%;">
		<view class="inv-h-w">
			<!-- <view :class="['inv-h',Inv==0?'inv-h-se':'']" @click="unsubmit">基本信息</view>
			<view :class="['inv-h',Inv==1?'inv-h-se':'']" @click="submit">闭合</view>
		<view :class="['inv-h',Inv==2?'inv-h-se':'']" @click="yiji">一级审核</view>
		<view :class="['inv-h',Inv==2?'inv-h-se':'']" @click="jier">二级审核</view> -->
			<view :class="['inv-h',Inv==0?'inv-h-se':'']" @click="yj_searchForm(Inv=0)">基本信息</view>
			<view :class="['inv-h',Inv==1?'inv-h-se':'']" @click="yj_searchForm(Inv=1)">闭合</view>
			<view v-if="statusNum>=2" :class="['inv-h',Inv==2?'inv-h-se':'']" @click="yj_searchForm(Inv=2)">
				一级审核</view>
			<view v-if="statusNum>=3" :class="['inv-h',Inv==3?'inv-h-se':'']" @click="yj_searchForm(Inv=3)">二级审核</view>

		</view>

		<view class="" style="position: absolute;width: 100%;margin-top: 100upx">
			<view class="formPage" v-show="Inv==0">
				<form>
					<fromItem title="样品名称" :data="totalData.fSamplename" flex="right" nameColor="#989898"
						projectName="#343434">
					</fromItem>
					<fromItem title="样品编号" :data="totalData.fSamplenumber" flex="right" nameColor="#989898"
						projectName="#343434">
					</fromItem>
					<fromItem title="报告编号" :data="totalData.fReportnumber" flex="right" nameColor="#989898"
						projectName="#343434">
					</fromItem>
					<fromItem title="报告日期" :data="totalData.fCommissiondates" flex="right" nameColor="#989898"
						projectName="#343434">
					</fromItem>
					<fromItem title="工程部位/用途" :data="totalData.fIntendeduse" flex="right" nameColor="#989898"
						projectName="#343434">
					</fromItem>
					<view class="cu-form-group" style="margin-bottom: 50upx;">
					</view>
					<div class="wrapper" v-if="appliance==1">
						<div class="list">
							<text class="text" @click="clickNum()">保存</text>

						</div>
					</div>
				</form>
			</view>
			<view class="formPage" v-show="Inv==1">
				<form>
					<view style="width: 100%;">
						<cLabel title='处理方式' v-model='closeFormObj.fProcessing' :disabled="bihe"
							:dataText='closeFormObj.fProcessing' rightIcon='' mode='text' />
						<cLabel title='处理日期' over="calc(5em + 15px)" :dataText='closeFormObj.fProcessdates' must="must"
							:disabled="true" v-model='closeFormObj.fProcessdates' mode='date1' :flagNum="flagNum" />
						<cLabel title='处理人' v-model='closeFormObj.fProcessusername' :disabled="true"
							:dataText='closeFormObj.fProcessusername' rightIcon='' mode='text' />


						<cLabel title='不合格参数及结果' v-model='closeFormObj.fNonresult' :dataText='closeFormObj.fNonresult'
							rightIcon='' mode='textarea' />

						<view class="cu-bar bg-white" style="margin-top: 15upx;">

							<view class="action">
								<image src="@/static/unscope.png" mode=""
									style="width: 30upx;height: 30upx;vertical-align: middle;">
									附件资料
							</view>
							<view class="action">
								{{fileList.length}}/{{count}}
							</view>
						</view>
						<view class="cu-form-group">
							<view class="grid col-4 grid-square flex-sub">
								<view class="bg-img" v-for="(item,index) in fileList" :key="index" :data-url="item.url">
									<image @tap="pdfPage(item.name, item.url)" v-if="item.fFileType=='.pdf'"
										src="@/static/organization.png" mode="aspectFill"></image>
									<view v-else style="height: 100%;" :data-url="item.url">
										<image :src="item.url" @tap="ViewImage($event, item.url)"></image>
									</view>
									<view v-if="!bihe" class="cu-tag bg-red" @tap.stop="DelFile($event,item.fId,index)">
										<text class='cuIcon-close'></text>
									</view>
								</view>
								<view v-if="(fileList.length<count)&&!bihe">
									<lsj-upload ref="lsjUpload" childId="upload" :width="heights" :height="heights"
										:option="option" :size="size" :debug="debug" :instantly="instantly"
										@progress="onprogress" @change="onChange" :count='count'>
										<view class="solids" style="width: 156rpx;height: 156rpx;">
											<text class='cuIcon-add'></text>
										</view>
									</lsj-upload>

								</view>

							</view>
						</view>

					</view>

					<view class="cu-form-group" style="margin-bottom: 100upx;">
					</view>
					<div class="wrapper" v-if="appliance==1">
						<div class="list">
							<text class="text" @click="clickNum()">保存</text>
							<!-- <text class="text" @click="clickNum('1')">提交</text> -->
						</div>
					</div>
				</form>
			</view>
			<view class="formPage" v-show="Inv==2">
				<form>
					<cLabel  title='审核结果' :dataText='FirstLevel.fCheckresult1' :selectList="ifArr" :disabled="yiji"
						v-model='FirstLevel.fCheckresult1' mode='selector2' :flagNum="flagNum" name="fItemName" />
					<cLabel title='审核人' v-model='FirstLevel.fCheckusername1' :disabled="true"
						:dataText='FirstLevel.fCheckusername1' rightIcon='' mode='text' />
					<cLabel title='处理日期' over="calc(5em + 15px)" :dataText='FirstLevel.fCheckdate1s' must="must"
						:disabled="true" v-model='FirstLevel.fCheckdate1s' mode='date1' :flagNum="flagNum" />
					<cLabel :disabled="yiji" title='审核意见' v-model='FirstLevel.fCheckopinion1' :dataText='FirstLevel.fCheckopinion1'
						rightIcon='' mode='textarea' />
					<view style="width: 100%;">
						





						<view class="cu-bar bg-white" style="margin-top: 15upx;">

							<view class="action">
								<image src="@/static/unscope.png" mode=""
									style="width: 30upx;height: 30upx;vertical-align: middle;">
									附件资料
							</view>
							<view class="action">
								{{FirstList.length}}/{{count}}
							</view>
						</view>
						<view class="cu-form-group">
							<view class="grid col-4 grid-square flex-sub">
								<view class="bg-img" v-for="(item,index) in FirstList" :key="index"
									:data-url="item.url">
									<image @tap="pdfPage(item.name, item.url)" v-if="item.fFileType=='.pdf'"
										src="@/static/organization.png" mode="aspectFill"></image>
									<view v-else style="height: 100%;" :data-url="item.url">
										<image :src="item.url" @tap="ViewImage($event, item.url)"></image>
									</view>
									<view v-if="!yiji" class="cu-tag bg-red" @tap.stop="DelFile($event,item.fId,index)">
										<text class='cuIcon-close'></text>
									</view>
								</view>
								<view v-if="(FirstList.length<count)&&!yiji">
									<lsj-upload ref="lsjUpload" childId="upload" :width="heights" :height="heights"
										:option="option" :size="size" :debug="debug" :instantly="instantly"
										@progress="onprogress" @change="onChange" :count='count'>
										<view class="solids" style="width: 156rpx;height: 156rpx;">
											<text class='cuIcon-add'></text>
										</view>
									</lsj-upload>

								</view>

							</view>
						</view>




					</view>

					<view class="cu-form-group" style="margin-bottom: 100upx;">
					</view>
					<div class="wrapper" v-if="appliance==1">
						<div class="list">
							<text class="text" @click="clickNum()">保存</text>
							<!-- <text class="text" @click="clickNum('1')">提交</text> -->
						</div>
					</div>
				</form>
			</view>
			<view class="formPage" v-show="Inv==3">
				<form>
					<view style="width: 100%;">
						<cLabel title='审核结果' :dataText='secondLevel.fCheckresult2' :selectList="ifArr"
							v-model='secondLevel.fCheckresult2' mode='selector2' :flagNum="flagNum2" name="fItemName" />
						<cLabel title='审核人' v-model='secondLevel.fCheckusername2' :disabled="true"
							:dataText='secondLevel.fCheckusername2' rightIcon='' mode='text' />
						<cLabel title='处理日期' over="calc(5em + 15px)" :dataText='secondLevel.fCheckdate2s' must="must"
							:disabled="true" v-model='secondLevel.fCheckdate2s' mode='date1' :flagNum="flagNum2" />
						<cLabel title='审核意见' v-model='secondLevel.fCheckopinion2' :dataText='secondLevel.fCheckopinion2'
							rightIcon='' mode='textarea' />
						<view class="cu-bar bg-white" style="margin-top: 15upx;">

							<view class="action">
								<image src="@/static/unscope.png" mode=""
									style="width: 30upx;height: 30upx;vertical-align: middle;">
									附件资料
							</view>
							<view class="action">
								{{secondList.length}}/{{count}}
							</view>
						</view>
						<view class="cu-form-group">
							<view class="grid col-4 grid-square flex-sub">
								<view class="bg-img" v-for="(item,index) in secondList" :key="index"
									:data-url="item.url">
									<image @tap="pdfPage(item.name, item.url)" v-if="item.fFileType=='.pdf'"
										src="@/static/organization.png" mode="aspectFill"></image>
									<view v-else style="height: 100%;" :data-url="item.url">
										<image :src="item.url" @tap="ViewImage($event, item.url)"></image>
									</view>
									<view v-if="!erji" class="cu-tag bg-red" @tap.stop="DelFile($event,item.fId,index)">
										<text class='cuIcon-close'></text>
									</view>
								</view>
								<view v-if="(secondList.length<count)&&!erji">
									<lsj-upload ref="lsjUpload" childId="upload" :width="heights" :height="heights"
										:option="option" :size="size" :debug="debug" :instantly="instantly"
										@progress="onprogress" @change="onChange" :count='count'>
										<view class="solids" style="width: 156rpx;height: 156rpx;">
											<text class='cuIcon-add'></text>
										</view>
									</lsj-upload>

								</view>

							</view>
						</view>


					</view>

					<view class="cu-form-group" style="margin-bottom: 100upx;">
					</view>
					<div class="wrapper" v-if="appliance==1">
						<div class="list">
							<text class="text" @click="clickNum()">保存</text>
							<!-- <text class="text" @click="clickNum('1')">提交</text> -->
						</div>
					</div>
				</form>
			</view>
			<loading :shadeShow="shadeShow" :shadeClick="false" :backgroundColor="backgroundColor" :width="width"
				:height="height" ref="loading" :custom="false" :type="1" @callback="callback()">
			</loading>
			<!-- 		<tki-tree ref="company" nodeKey="fCompanyid" rangeKey="fShortname" :selectParent="selectParent"
				:multiple="multiple" :range="companyTree" :foldAll="flod" @confirm="treeConfirm" @cancel="treeCancel">
			</tki-tree> -->

		</view>
	</view>
</template>
<script src="./index.js">
</script>
<style scoped lang="less">
	@import './index.less';
</style>
